home *** CD-ROM | disk | FTP | other *** search
- Path: news.primenet.com!not-for-mail
- From: gbe@primenet.com (Gary Edstrom)
- Newsgroups: comp.lang.c++
- Subject: Help Wanted: Win95 System Tray Icons: Getting Coordinates of Mouse Click
- Date: 15 Mar 1996 16:45:01 -0700
- Organization: Sequoia Software
- Sender: root@primenet.com
- Message-ID: <3149fe39.169953417@news.primenet.com>
- X-Posted-By: ip040.lax.primenet.com
- X-Newsreader: Forte Agent .99d/32.182
-
- I have written a small Windows 95 program that makes use of the system tray in
- Windows 95. I place an icon in the tray and I would like to cause a menu to
- pop up when the user right-clicks on one of my icons. I would like this popup
- menu to appear right next to where the operator clicked the mouse. I have
- succeeded in getting the menu to pop up on the screen, but I have not been able
- to figure out how to get the coordinates of the click for the purpose of
- locating the popup menu next to the click.
-
- I would know how to do this if I was clicking the mouse anywhere in the client
- area of my application. The tray icons, however, reside outside of my client
- area. I have been able to receive mouse message callbacks in my callback
- procedure for the system tray, but these callback messages do not seem to
- include mouse position information.
-
- I have seen this done in several different applications. For example, when you
- right-click on the System Agent tray icon, you get a popup menu right by where
- you clicked on the icon. This is what I wish to do in my application.
-
- Can anyone help?
-
- Thanks in advance.
-
- --
- Gary Edstrom <gbe@primenet.com> | Sequoia Software
- PO Box 9573 | Programming & Technical Services
- Glendale CA 91226-0573 | PGP Key ID: 0x1A0D44BD
- PGP Fingerprint: 72 AA 4F 73 05 53 89 C6 8A EE F4 EE D1 C0 13 8D
-